<template>
    <div class="shopping">
        <div class="big">
            <van-button type="default" class="service">
            <van-icon name="smile-o" />
                <p>联系商家</p>
            </van-button>    
            <div class="butt-bg">
                <button class="comNum" @click="menu">
                    <van-badge :content="1" max="99" />
                    <van-icon name="shopping-cart" />
                </button>
                <div class="price">
                    <p>￥000</p>
                    <span>另需配送费00元 | 支持自取</span>
                </div>
                <button class="settlement">
                    去结算
                </button>
            </div>
        </div>
        <van-action-sheet v-model="show">
            <div class="content">
                <div class="discount">
                    新用户下单立减000元
                </div>
                <div class="empty">
                    <span>购物车</span>
                    <span>清空购物车</span>
                </div>
                <ul>
                    <li>
                        <span>内容内容内容sasdadadaad</span>
                        <p>￥000</p>
                        <van-stepper v-model="value" theme="round" button-size="22" disable-input />
                    </li>
                    <li>
                        <span>内容内容内容sasdadadaad</span>
                        <p>￥000</p>
                        <van-stepper v-model="value" theme="round" button-size="22" disable-input />
                    </li>
                    <li>
                        <span>内容内容内容sasdadadaad</span>
                        <p>￥000</p>
                        <van-stepper v-model="value" theme="round" button-size="22" disable-input />
                    </li>
                </ul>
            </div>
        </van-action-sheet>
    </div>
</template>

<script lang="ts">
    import { Component, Vue } from 'vue-property-decorator';

    @Component
    export default class APP extends Vue {
        show:Boolean = false;
        value:Number = 1;
        menu(){
            this.show = true;
        }
    }   
</script>

<style scoped>
body{
    line-height: 1;
}
.shopping{
    display: flex;
    justify-content: center;
    position: fixed;
    width: 100%;
    bottom: 25px;
}
.big{
    width: 100%;
    display: flex;
    z-index: 10000;
    margin-left: 20px;
}
.service{
    height: 52px;
    width: 78px;
    font-size: 12px;
    background: #222222;
    color: #999;
    border-radius: 30px 0 0 30px;
    border: none;
}
.service .van-icon {
    font-size: 20px;
    line-height: 0;
    margin-top: 16px;
}
.service p {
    line-height: 0;
}
.butt-bg{
    width: 70%;
    height: 52px;
    background: #222;
    margin-left: 4px;
    border-radius: 0 26px 26px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.comNum{
    background: #ffc300;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    margin-left: 8px;
    position: relative;
    border: none;
}
.comNum .van-icon {
    font-size: 24px;
    color: #222;
}
.van-badge{
    position:absolute;
    top: 0;
    right: 0;
    border: none;
}
.settlement{
    border: none;
    font-size: 14px;
    width: 80px;
    height: 100%;
    background: #ffc300;
    border-radius: 0 26px 26px 0;
    font-weight:600;
}
.price{
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}
.price span{
    font-size: 12px;
    line-height: 0;
    color: #999;
    padding-top: 4px;
}
.price p{
    
    color: #fff;
    margin-top: 6px;
    line-height: 0;
}
.content {
    padding: 0 0 80px;
}
.discount{
    background: #fee7c8;
    font-size: 12px;
    line-height: 32px;
    color: #ff6a00;
}
.empty{
    display: flex;
    justify-content: space-between;
    padding: 4px 12px;
    font-size: 12px;
}
.content li {
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.content li p{
    color:#ff4400;
    font-weight: 600;
}
.content li span{
    display: inline-block;
    text-align: start;
    width: 40%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
</style>